﻿using System;
using System.ComponentModel;
using System.Runtime.InteropServices;

namespace Teigha.Core
{
	public class OdGiSkyParameters : IDisposable
	{
		[EditorBrowsable(EditorBrowsableState.Never)]
		public OdGiSkyParameters(IntPtr cPtr, bool cMemoryOwn)
		{
			this.swigCMemOwn = cMemoryOwn;
			this.swigCPtr = new HandleRef(this, cPtr);
		}

		[EditorBrowsable(EditorBrowsableState.Never)]
		public static HandleRef getCPtr(OdGiSkyParameters obj)
		{
			if (obj != null)
			{
				return obj.swigCPtr;
			}
			return new HandleRef(null, IntPtr.Zero);
		}

		~OdGiSkyParameters()
		{
			this.Dispose();
		}

		public virtual void Dispose()
		{
			if (this.swigCPtr.Handle != IntPtr.Zero)
			{
				if (this.swigCMemOwn)
				{
					lock (this.locker)
					{
						if (this.swigCPtr.Handle != IntPtr.Zero && this.swigCMemOwn)
						{
							this.swigCMemOwn = false;
							GlobalsPINVOKE.delete_OdGiSkyParameters(this.swigCPtr);
						}
					}
					this.swigCMemOwn = false;
				}
				this.swigCPtr = new HandleRef(null, IntPtr.Zero);
			}
			GC.SuppressFinalize(this);
		}

		public OdGiSkyParameters() : this(GlobalsPINVOKE.new_OdGiSkyParameters(), true)
		{
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public bool IsEqual(OdGiSkyParameters arg0)
		{
			bool result = GlobalsPINVOKE.OdGiSkyParameters_IsEqual(this.swigCPtr, OdGiSkyParameters.getCPtr(arg0));
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setIllumination(bool enable)
		{
			GlobalsPINVOKE.OdGiSkyParameters_setIllumination(this.swigCPtr, enable);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public bool illumination()
		{
			bool result = GlobalsPINVOKE.OdGiSkyParameters_illumination(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setIntensityFactor(double intensity)
		{
			GlobalsPINVOKE.OdGiSkyParameters_setIntensityFactor(this.swigCPtr, intensity);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public double intensityFactor()
		{
			double result = GlobalsPINVOKE.OdGiSkyParameters_intensityFactor(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setHaze(double haze)
		{
			GlobalsPINVOKE.OdGiSkyParameters_setHaze(this.swigCPtr, haze);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public double haze()
		{
			double result = GlobalsPINVOKE.OdGiSkyParameters_haze(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setHorizonHeight(double height)
		{
			GlobalsPINVOKE.OdGiSkyParameters_setHorizonHeight(this.swigCPtr, height);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public double horizonHeight()
		{
			double result = GlobalsPINVOKE.OdGiSkyParameters_horizonHeight(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setHorizonBlur(double blur)
		{
			GlobalsPINVOKE.OdGiSkyParameters_setHorizonBlur(this.swigCPtr, blur);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public double horizonBlur()
		{
			double result = GlobalsPINVOKE.OdGiSkyParameters_horizonBlur(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setGroundColor(OdCmEntityColor color)
		{
			GlobalsPINVOKE.OdGiSkyParameters_setGroundColor(this.swigCPtr, OdCmEntityColor.getCPtr(color));
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public OdCmEntityColor groundColor()
		{
			OdCmEntityColor result = new OdCmEntityColor(GlobalsPINVOKE.OdGiSkyParameters_groundColor(this.swigCPtr), true);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setNightColor(OdCmEntityColor color)
		{
			GlobalsPINVOKE.OdGiSkyParameters_setNightColor(this.swigCPtr, OdCmEntityColor.getCPtr(color));
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public OdCmEntityColor nightColor()
		{
			OdCmEntityColor result = new OdCmEntityColor(GlobalsPINVOKE.OdGiSkyParameters_nightColor(this.swigCPtr), true);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setAerialPerspective(bool apply)
		{
			GlobalsPINVOKE.OdGiSkyParameters_setAerialPerspective(this.swigCPtr, apply);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public bool aerialPerspective()
		{
			bool result = GlobalsPINVOKE.OdGiSkyParameters_aerialPerspective(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setVisibilityDistance(double distance)
		{
			GlobalsPINVOKE.OdGiSkyParameters_setVisibilityDistance(this.swigCPtr, distance);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public double visibilityDistance()
		{
			double result = GlobalsPINVOKE.OdGiSkyParameters_visibilityDistance(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setDiskScale(double scale)
		{
			GlobalsPINVOKE.OdGiSkyParameters_setDiskScale(this.swigCPtr, scale);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public double diskScale()
		{
			double result = GlobalsPINVOKE.OdGiSkyParameters_diskScale(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setGlowIntensity(double intensity)
		{
			GlobalsPINVOKE.OdGiSkyParameters_setGlowIntensity(this.swigCPtr, intensity);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public double glowIntensity()
		{
			double result = GlobalsPINVOKE.OdGiSkyParameters_glowIntensity(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setDiskIntensity(double intensity)
		{
			GlobalsPINVOKE.OdGiSkyParameters_setDiskIntensity(this.swigCPtr, intensity);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public double diskIntensity()
		{
			double result = GlobalsPINVOKE.OdGiSkyParameters_diskIntensity(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setSolarDiskSamples(ushort samples)
		{
			GlobalsPINVOKE.OdGiSkyParameters_setSolarDiskSamples(this.swigCPtr, samples);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public ushort solarDiskSamples()
		{
			ushort result = GlobalsPINVOKE.OdGiSkyParameters_solarDiskSamples(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setSunDirection(OdGeVector3d sundir)
		{
			GlobalsPINVOKE.OdGiSkyParameters_setSunDirection(this.swigCPtr, OdGeVector3d.getCPtr(sundir));
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public OdGeVector3d sunDirection()
		{
			OdGeVector3d result = new OdGeVector3d(GlobalsPINVOKE.OdGiSkyParameters_sunDirection(this.swigCPtr), false);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setRedBlueShift(double redBlueShift)
		{
			GlobalsPINVOKE.OdGiSkyParameters_setRedBlueShift(this.swigCPtr, redBlueShift);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public double redBlueShift()
		{
			double result = GlobalsPINVOKE.OdGiSkyParameters_redBlueShift(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		public void setSaturation(double saturation)
		{
			GlobalsPINVOKE.OdGiSkyParameters_setSaturation(this.swigCPtr, saturation);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
		}

		public double saturation()
		{
			double result = GlobalsPINVOKE.OdGiSkyParameters_saturation(this.swigCPtr);
			if (GlobalsPINVOKE.SWIGPendingException.Pending)
			{
				throw GlobalsPINVOKE.SWIGPendingException.Retrieve();
			}
			return result;
		}

		private object locker = new object();

		private HandleRef swigCPtr;

		protected bool swigCMemOwn;
	}
}
